#ifndef SHAPE_H
#define SHAPE_H
/*!
  * \file drawshape.h
  * \version 0.1
  */
#include <QRect>
#include <QPoint>
/*!
  * \enum ShapeType
  * \brief type of the shape
  */
enum ShapeType { ROI, Rectangle, Line, Circle, null };
/*!
  * \class DrawShape
  * \brief shape on image
  * DrawShape (ROI, rectangle...) show on an image
  */
class DrawShape
{
private:
    int x1,y1,x2,y2;
    ShapeType type;
public:

    DrawShape();
    /*!
      * \fn DrawShape(ShapeType typ, int left, int top, int right, int bottom );
      * \brief constructor with with four int for coordinates
      */
    DrawShape(ShapeType typ, int left, int top, int right, int bottom );
    /*!
      * \fn DrawShape(ShapeType typ, QPoint topLeft, QPoint botRight);
      * \brief constructor with with two QPoints for coordinates
      */
    DrawShape(ShapeType typ, QPoint topLeft, QPoint botRight);
    /*!
      * \fn DrawShape(ShapeType typ, QRect coord);
      * \brief constructor with QRect for coordinates
      */
    DrawShape(ShapeType typ, QRect coord);
    /*!
      * \fn QPoint left() const;
      * \brief return left of the shape
      */
    int left() const;
    /*!
      * \fn QPoint top() const;
      * \brief return top of the shape
      */
    int top() const;
    /*!
      * \fn QPoint right() const;
      * \brief return right of the shape
      */
    int right() const;
    /*!
      * \fn QPoint bottom() const;
      * \brief return bottom of the shape
      */
    int bottom() const;
    /*!
      * \fn QPoint topLeft() const;
      * \brief return left of the shape
      */
    QPoint topLeft() const;
    /*!
      * \fn QPoint botRight() const;
      * \brief return point on left top
      */
    QPoint botRight() const;
    /*!
      * \fn QRect coordinates() const;
      * \brief return point on right bottom
      */
    QRect coordinates() const;
    /*!
      * \fn ShapeType type() const;
      * \brief return type of the shape
      */
    ShapeType getType() const;
};

#endif // SHAPE_H
